package com.school.untils;

import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Regular {
    // 获取字符串中的数字
    public static String getStringNum(String character){
        String regEx="[^0-9]";
        Pattern p = Pattern.compile(regEx);
        Matcher m = p.matcher(character);
        String stringNum = m.replaceAll("").trim();
        return stringNum;
    }
}
